package com.ruoyi.system.service.impl;

import com.ruoyi.common.core.utils.DateUtils;
import com.ruoyi.system.domain.SysContractCloan;
import com.ruoyi.system.mapper.SysContractCloanMapper;
import com.ruoyi.system.service.ISysContractCloanService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * 【请填写功能名称】Service业务层处理
 * 
 * @author paul
 * @date 2023-06-19
 */
@Service
public class SysContractCloanServiceImpl implements ISysContractCloanService
{
    @Resource
    private SysContractCloanMapper sysContractCloanMapper;

    /**
     * 查询【请填写功能名称】
     * 
     * @param id 【请填写功能名称】主键
     * @return 【请填写功能名称】
     */
    @Override
    public SysContractCloan selectSysContractCloanById(Long id)
    {
        return sysContractCloanMapper.selectSysContractCloanById(id);
    }

    /**
     * 查询【请填写功能名称】列表
     * 
     * @param sysContractCloan 【请填写功能名称】
     * @return 【请填写功能名称】
     */
    @Override
    public List<SysContractCloan> selectSysContractCloanList(SysContractCloan sysContractCloan)
    {
        return sysContractCloanMapper.selectSysContractCloanList(sysContractCloan);
    }

    /**
     * 新增【请填写功能名称】
     * 
     * @param sysContractCloan 【请填写功能名称】
     * @return 结果
     */
    @Override
    public int insertSysContractCloan(SysContractCloan sysContractCloan)
    {
        sysContractCloan.setCreateTime(DateUtils.getNowDate());
        return sysContractCloanMapper.insertSysContractCloan(sysContractCloan);
    }

    /**
     * 修改【请填写功能名称】
     * 
     * @param sysContractCloan 【请填写功能名称】
     * @return 结果
     */
    @Override
    public int updateSysContractCloan(SysContractCloan sysContractCloan)
    {
        sysContractCloan.setUpdateTime(DateUtils.getNowDate());
        return sysContractCloanMapper.updateSysContractCloan(sysContractCloan);
    }

    /**
     * 批量删除【请填写功能名称】
     * 
     * @param ids 需要删除的【请填写功能名称】主键
     * @return 结果
     */
    @Override
    public int deleteSysContractCloanByIds(Long[] ids)
    {
        return sysContractCloanMapper.deleteSysContractCloanByIds(ids);
    }

    /**
     * 删除【请填写功能名称】信息
     * 
     * @param id 【请填写功能名称】主键
     * @return 结果
     */
    @Override
    public int deleteSysContractCloanById(Long id)
    {
        return sysContractCloanMapper.deleteSysContractCloanById(id);
    }
}
